package com.example.hangzhou.welbeing.mytestdemoapp.activity;

import android.content.Intent;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v7.app.AppCompatActivity;
import android.widget.Button;
import android.widget.TextView;

import com.example.hangzhou.welbeing.mytestdemoapp.R;

import butterknife.Bind;
import butterknife.ButterKnife;
import butterknife.OnClick;
import cn.jesse.nativelogger.NLogger;

/**
 * 杭州惟君医疗科技有限公司10
 * Created by 20433 on 2018/4/8
 *
 * @desc 东风山河绿，春已不折柳，繁花看不尽，处处惹人留
 * @desc 佛祖镇楼，bug辟容易
 */

public class MyThreedActivity extends AppCompatActivity {
    @Bind(R.id.button5)
    Button button5;
    @Bind(R.id.textView5)
    TextView textView5;

    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_my_threed);
        ButterKnife.bind(this);
        textView5.setText(getIntent().getStringExtra("step"));
    }

    @OnClick(R.id.button5)
    public void onViewClicked() {
        Intent intent=   new Intent(MyThreedActivity.this, MyOneActivity.class);
        intent.putExtra("step","第四");
        intent.setFlags(Intent.FLAG_ACTIVITY_BROUGHT_TO_FRONT);// 创建  FLAG_ACTIVITY_CLEAR_TASK
        startActivity(intent);
    }
    @Override
    protected void onNewIntent(Intent intent) {
        super.onNewIntent(intent);
        NLogger.e("TAG","===============2======="+intent.getStringExtra("step"));
        textView5.setText(intent.getStringExtra("step"));
    }
}
